#include "D3D9RenderState.h"

#include <Core/Factory.h>
#define WIN32_LEAN_AND_MEAN
#define D3D_DISABLE_9EX
#include <d3d9.h>

namespace Render
{
__ImplementClass(Render::CD3D9RenderState, 'RS09', Render::CRenderState);

const D3DRENDERSTATETYPE CD3D9RenderState::D3DStates[D3D9_RS_COUNT] =
{
	// Rasterizer
	D3DRS_FILLMODE,
	D3DRS_CULLMODE,
	D3DRS_MULTISAMPLEANTIALIAS,
	D3DRS_MULTISAMPLEMASK,
	D3DRS_ANTIALIASEDLINEENABLE,
	D3DRS_DEPTHBIAS,
	D3DRS_SLOPESCALEDEPTHBIAS,
	D3DRS_SCISSORTESTENABLE,

	// Depth-stencil
	D3DRS_ZENABLE,
	D3DRS_ZWRITEENABLE,
	D3DRS_ZFUNC,
	D3DRS_STENCILENABLE,
	D3DRS_STENCILFAIL,
	D3DRS_STENCILZFAIL,
	D3DRS_STENCILPASS,
	D3DRS_STENCILFUNC,
	D3DRS_STENCILREF,
	D3DRS_STENCILMASK,
	D3DRS_STENCILWRITEMASK,
	D3DRS_TWOSIDEDSTENCILMODE,
	D3DRS_CCW_STENCILFAIL,
	D3DRS_CCW_STENCILZFAIL,
	D3DRS_CCW_STENCILPASS,
	D3DRS_CCW_STENCILFUNC,

	// Blend
	D3DRS_SRCBLEND,
	D3DRS_DESTBLEND,
	D3DRS_ALPHABLENDENABLE,
	D3DRS_BLENDOP,
	D3DRS_SEPARATEALPHABLENDENABLE,
	D3DRS_SRCBLENDALPHA,
	D3DRS_DESTBLENDALPHA,
	D3DRS_BLENDOPALPHA,
	D3DRS_COLORWRITEENABLE,
	//D3DRS_COLORWRITEENABLE1,
	//D3DRS_COLORWRITEENABLE2,
	//D3DRS_COLORWRITEENABLE3,
	//D3DRS_TEXTUREFACTOR, // Color for blending
	D3DRS_BLENDFACTOR,

	// Misc
	D3DRS_ALPHATESTENABLE,
	D3DRS_ALPHAREF,
	D3DRS_ALPHAFUNC,
	D3DRS_CLIPPLANEENABLE
};
//---------------------------------------------------------------------

}